package main.java.design.template;

/**
 * <p></p>
 *
 * @author : wangdejian
 * @version 1.0
 * @date : 2020/6/17 21:09
 */
public abstract class AbstractClass {

    protected abstract void primitiveOperation1();
    protected abstract void primitiveOperation2();
    protected abstract void primitiveOperation3();

    // 模板方法，给出了逻辑的骨架,逻辑的组成是一些相应的抽象操作，他们都推迟到子类实现
    public final void templateMthod() {
        primitiveOperation1();
        primitiveOperation2();
        primitiveOperation3();
    }
}
